package com.example.aicompositiongrader.dao;

import com.example.aicompositiongrader.database.HistoryRecord;

import androidx.room.Dao;
import androidx.room.Delete;
import androidx.room.Insert;
import androidx.room.Query;

import java.util.List;

@Dao
public interface HistoryDao {
    @Query("SELECT * FROM history_records ORDER BY timestamp DESC")
    List<HistoryRecord> getAll();

    @Insert
    void insert(HistoryRecord record);

    @Delete
    void delete(HistoryRecord record);
}